import { createWindow } from './window'
import {
  ignoreMouseEvent,
  openConfigWindow,
  openUrl,
  registerIpcMain,
  setWindowSize,
  setAutoLaunch,
  isAutoLaunchEnabled
} from './ipc'
import { registerShortCut } from './shortCut'
import { createTray } from './taryMenu'

export function init() {
  const win = createWindow()
  registerIpcMain(win)
  registerShortCut(win)
  ignoreMouseEvent(win)
  openConfigWindow()
  openUrl()
  createTray(win)
  setWindowSize(win)
  setAutoLaunch()
  isAutoLaunchEnabled(win)
}
